package com.yj_app.qualitytest.activity.login.contract;

import androidx.lifecycle.LifecycleOwner;

import com.yj_app.qualitytest.base.mvp.BaseModel;
import com.yj_app.qualitytest.base.mvp.BasePresenter;
import com.yj_app.qualitytest.base.mvp.BaseView;
import com.yj_app.qualitytest.callback.DialogCallback;
import com.yj_app.qualitytest.info.BaseInfo;
import com.yj_app.qualitytest.info.CompanyInfo;
import com.yj_app.qualitytest.info.Loginfo;

import java.util.List;

public interface LoginContract {
    interface Model extends BaseModel {
        void getCompanies(DialogCallback<BaseInfo<List<CompanyInfo>>> stringDialogCallback);

        void getLoginfo(String username, String userpwd, DialogCallback<String> stringDialogCallback);

        void getLoginfo2(String msg2json, DialogCallback<String> stringDialogCallback);

        void getCompanies2(String s, DialogCallback<String> stringDialogCallback);
    }

    interface View extends BaseView, LifecycleOwner {
        void reCompaniesData(List<CompanyInfo> list);

        void reLoginData(Loginfo body);
    }

    interface Presenter extends BasePresenter{
        void getCompanies();

        void login(String username, String userpwd);
    }
}
